package com.niu.business.utils.date;

import com.niu.business.constent.Constant;
import org.springframework.stereotype.Component;

import java.text.SimpleDateFormat;
import java.util.Date;

@Component
public class DateUtils {


    public static String formatDate(Date date){
        SimpleDateFormat dateFormat = new SimpleDateFormat(Constant.YYYY_MM_DD_HH_MM_SS);
        return dateFormat.format(date);
    }
}
